<ion-view view-title="信用收益">
	<ion-content style="background-color:#f5f5f5;">
		
		<div style="background-color: #00aaee;color: white;height: 240px;">
  			<div style="margin-left: 10px;margin-right: 10px;">
  				<div class="row">
	   				<div class="col col-100" style="height: 30px;line-height: 30px;font-size: 13px;color: #e1f4fb;text-align: right;">
	   					<span>普通卡 LV{{data.creditLevel}}</span>
	   				</div>
	   			</div>
	   			
  				<div class="row">
	   				<div class="col col-100" style="height: 40px;line-height: 40px;font-size: 14px;color: #e1f4fb;text-align: center;">待收益总额</div>
	   			</div>
	   			<div style="font-size: 80px;height: 80px;line-height: 80px;text-align: center;" id="unAmount">{{unAmount}}</div>
	   			<div style="line-height: 20px;height: 20px;border-bottom: 1px solid #39bdf2;"></div>
	   			<div style="height: 50px;color: #e1f4fb;margin-left: 10px;font-size: 13px;text-align: center;" id='xy'>	  		
		   			<div style="float: left;width: 50%;margin-top: 10px;">{{data.creditValue}}<br>当前信用身价</div>
		   			<div style="float: left;width: 50%;margin-top: 10px;">{{data.tlevel.yieldRate*100 | number:2}}%<br>年化收益率</div>
	   			</div>
    		</div>
    	</div>
    	
    	<div style="height: 100px;line-height:100px;background: #f5f5f9;text-align: center;">
    		<button class="button  button-positive" ng-click="incomeToBalance()" style="width: 90%;margin-top: 25px;background-color: #00aaee;font-size: 20px;">
			  收益转余额
			</button>
    	</div>
    	
    	<div ng-if="data.creditValue<2000" style="text-align: center;color: red;">信用身价＜2000不能产生收益</div>
    	
    	<div ng-if="data.creditValue>=2000" class="list" style="margin-top:-1px;" delegate-handle="changScroll">
    		<div style="text-align: right;color: #7f817f;height: 20px;background: #f5f5f9;">每日领取信用收益&nbsp;&nbsp;</div>
				<a class="item" href="javascript:void(0);" style="padding: 0px;" ng-repeat="interest in creditInComes">	
					<div class="row">
						<div class="col-33"  style="color: #7f817f;text-align: center;width: 60px;height: 40px;font-size: 13px;min-height: 40px;min-width: 40px;line-height: 40px;">
			    			{{interest.createTime | date:'yyyy-MM-dd'}}
			    		</div> 
			    		<div class="col-33" style="text-align: center;width: 60px;height: 40px;font-size: 13px;min-height: 40px;min-width: 40px;line-height: 40px;">&nbsp;
			    			<font style="color:#f57d26;" size="3">+</font>
			    			<font style="color:#f57d26;" size="4">{{interest.interestAccount}}</font>
			    		</div>
			    		
			    		<div class="col-33"  style="color: #7f817f;text-align: center;">
		    				<button ng-if="interest.status==0" class="button button-positive" ng-click="receiveInterest('{{interest.interestId}}')" style="width: 40px;height: 40px;font-size: 13px;min-height: 40px;min-width: 40px;border-radius:50px;background: #00aaee;">
							  	领
							</button>
							<div ng-if="interest.status==1" style="font-size:13px;line-height: 40px;">
							  	已领
							</div>
							<div ng-if="interest.status==2" style="font-size:13px;line-height: 40px;">
							  	已过期
							</div>
			    		</div>
			    	</div>
				</a>
				<ion-infinite-scroll ng-if="noMore" on-infinite="loadCreditInComes()" distance="1%"></ion-infinite-scroll> 
			</div>
		</div>
		
	</ion-content>
</ion-view>